All Questions
6 questions
3votes
2answers
354views
Challenge: phone keypad to letters - return all possible strings
The challenge: Given a mapping of digits to letters (as in a phone number), and a digit string, return all possible letters the number could represent. You can assume each valid number in the ...
4votes
1answer
3kviews
Generate all possible combination of n-pair parentheses
The task is taken from LeetCode Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses. For example, given n = 3, a solution set is: ...
4votes
2answers
972views
PermCheck Codility
The following code gets 100% on the PermCheck task on Codility. It should be O(N). The question is: A non-empty array A consisting of N integers is given. A permutation is a sequence ...
2votes
2answers
130views
Forming all multiples of 3 using the given digits
I'm working on this kata from Codewars. The task is: Given a certain number, how many multiples of three could you obtain with its digits? Supose that you have the number 362. The numbers that can be ...
3votes
2answers
525views
Finding Permutations of Numbers
I'm trying to solve this challenge, which consists of finding the next biggest number formed by the digits of the passed in number. If it is impossible to find a number larger than the passed in ...
2votes
1answer
178views
Counting the ways to pick increasing sequences from sorted arrays
Preamble I am trying to learn JavaScript by writing code and looking up documentation, one problem at a time. I am already familiar with several "dynamic" languages, so I'm hoping to be productive ...